/**
 * 
 */
package com.ubo.graphviz.model.graph.statement;

import java.util.Collection;

import com.ubo.transform.dot.IDotVisitor;


/**
 * @author saludegu
 * 
 */
public class EdgeStatementNode implements IStatement {

	/**
	 * Identifiant du node Source.
	 */
	protected final int mIdFrom;

	/**
	 * Identifiant du node Cible.
	 */
	protected final int mIdTo;

	/**
	 * EdgeRHS de l'edgeStmt.
	 */
	protected EdgeRHS mEdgeRHS;

	/**
	 * Liste d'attributs.
	 */
	protected AttributeList mAttributes;

	/**
	 * ArrowHead.
	 */
	protected String mArrowHead;

	/**
	 * ArrowTail.
	 */
	protected String mArrowTail;

	/**
	 * Style de l'edge.
	 */
	protected String mStyle;

	/**
	 * Weight de l'edge.
	 */
	protected String mWeight;

	/**
	 * Couleur de l'edge.
	 */
	protected String mColor;

	/**
	 * Couleur de remplissage de l'edge.
	 */
	protected String mFillColor;

	/**
	 * Font de l'edge.
	 */
	protected String mFont;

	/**
	 * Taille de la font.
	 */
	protected String mFontSize;

	/**
	 * Label de l'edge.
	 */
	protected String mLabel;

	/**
	 * HeadLabel de l'edge.
	 */
	protected String mHeadLabel;

	/**
	 * TaileLabel de l'edge.
	 */
	protected String mTaileLabel;

	/**
	 * Line color de l'edge.
	 */
	protected String mLineColor;

	/**
	 * 
	 * Constructor
	 * 
	 * @param id
	 */
	public EdgeStatementNode(int idFrom, int idTo) {
		mIdFrom = idFrom;
		mIdTo = idTo;
	}

	/**
	 * @return the mEdgeRHS
	 */
	public EdgeRHS getEdgeRHS() {
		return mEdgeRHS;
	}

	/**
	 * @param mEdgeRHS
	 *            the mEdgeRHS to set
	 */
	public void setEdgeRHS(EdgeRHS mEdgeRHS) {
		this.mEdgeRHS = mEdgeRHS;
	}

	/**
	 * @return the mAttributes
	 */
	public AttributeList getAttributes() {
		return mAttributes;
	}

	/**
	 * Ajout d'un attribut à l'edge.
	 * 
	 * @param newAttribute
	 */
	public void addAttribute(Attribute newAttribute) {
		if (mAttributes == null)
			mAttributes = new AttributeList();
		mAttributes.addAttribute(newAttribute);
	}

	/**
	 * Ajout d'une collection d'attributs à l'edge.
	 * 
	 * @param attributes
	 */
	public void addAllAttributes(Collection<Attribute> attributes) {
		if (mAttributes == null)
			mAttributes = new AttributeList();
		mAttributes.addAllAttribute(attributes);
	}

	/**
	 * @return the mArrowHead
	 */
	public String getArrowHead() {
		return mArrowHead;
	}

	/**
	 * @param mArrowHead
	 *            the mArrowHead to set
	 */
	public void setArrowHead(String mArrowHead) {
		this.mArrowHead = mArrowHead;
	}

	/**
	 * @return the mArrowTail
	 */
	public String getArrowTail() {
		return mArrowTail;
	}

	/**
	 * @param mArrowTail
	 *            the mArrowTail to set
	 */
	public void setArrowTail(String mArrowTail) {
		this.mArrowTail = mArrowTail;
	}

	/**
	 * @return the mStyle
	 */
	public String getStyle() {
		return mStyle;
	}

	/**
	 * @param mStyle
	 *            the mStyle to set
	 */
	public void setStyle(String mStyle) {
		this.mStyle = mStyle;
	}

	/**
	 * @return the mWeight
	 */
	public String getWeight() {
		return mWeight;
	}

	/**
	 * @param mWeight
	 *            the mWeight to set
	 */
	public void setWeight(String mWeight) {
		this.mWeight = mWeight;
	}

	/**
	 * @return the mColor
	 */
	public String getColor() {
		return mColor;
	}

	/**
	 * @param mColor
	 *            the mColor to set
	 */
	public void setColor(String mColor) {
		this.mColor = mColor;
	}

	/**
	 * @return the mFillColor
	 */
	public String getFillColor() {
		return mFillColor;
	}

	/**
	 * @param mFillColor
	 *            the mFillColor to set
	 */
	public void setFillColor(String mFillColor) {
		this.mFillColor = mFillColor;
	}

	/**
	 * @return the mFont
	 */
	public String getFont() {
		return mFont;
	}

	/**
	 * @param mFont
	 *            the mFont to set
	 */
	public void setFont(String mFont) {
		this.mFont = mFont;
	}

	/**
	 * @return the mFontSize
	 */
	public String getFontSize() {
		return mFontSize;
	}

	/**
	 * @param mFontSize
	 *            the mFontSize to set
	 */
	public void setFontSize(String mFontSize) {
		this.mFontSize = mFontSize;
	}

	/**
	 * @return the mLabel
	 */
	public String getLabel() {
		return mLabel;
	}

	/**
	 * @param mLabel
	 *            the mLabel to set
	 */
	public void setLabel(String mLabel) {
		this.mLabel = mLabel;
	}

	/**
	 * @return the mHeadLabel
	 */
	public String getHeadLabel() {
		return mHeadLabel;
	}

	/**
	 * @param mHeadLabel
	 *            the mHeadLabel to set
	 */
	public void setHeadLabel(String mHeadLabel) {
		this.mHeadLabel = mHeadLabel;
	}

	/**
	 * @return the mTaileLabel
	 */
	public String getTaileLabel() {
		return mTaileLabel;
	}

	/**
	 * @param mTaileLabel
	 *            the mTaileLabel to set
	 */
	public void setTaileLabel(String mTaileLabel) {
		this.mTaileLabel = mTaileLabel;
	}

	/**
	 * @return the mLineColor
	 */
	public String getLineColor() {
		return mLineColor;
	}

	/**
	 * @param mLineColor
	 *            the mLineColor to set
	 */
	public void setLineColor(String mLineColor) {
		this.mLineColor = mLineColor;
	}

	/**
	 * 
	 * @return the mIdTo
	 */
	public int getIdTo() {
		return mIdTo;
	}

	/**
	 * @return the mIdFrom
	 */
	public int getIdFrom() {
		return mIdFrom;
	}

	/**
	 * @see com.ubo.graphviz.model.graph.statement.IStatement#generate(com.ubo.transform.dot.IDotVisitor)
	 */
	@Override
	public void generate(IDotVisitor<?> visitor) {
		visitor.generate(this);
	}

}
